home *** CD-ROM | disk | FTP | other *** search
/ Info-Mac 3 / Info_Mac_1994-01.iso / Development / General / Texx 0.3 / Shutdown.exec < prev    next >
Text File  |  1993-11-16  |  870b  |  28 lines

  1. /* Shutdown.exec */
  2. say 'Shutdown.exec';
  3. say 'Date of last change - 11/16/93';
  4. address finder;
  5. if rc = 0 then
  6. do   /* Address successfull */
  7.      /* If MS Word temp files exist, move them to the trash */
  8.      /* Set up a path to the system folder */
  9.      path BootDrive() || 'system folder';
  10.      do i = 1 to 4
  11.           if FileExists( 'Word Temp ' || i ) then
  12.                Move Selection 'Word Temp ' || i 0 0 BootDrive() || 'Trash';
  13.      end;
  14.      /* now empty the trash */
  15.         empty trash;
  16.      if rc <> 0 then
  17.          say 'Profile.exec -- Empty Trash failed';
  18.      /* Close all mounted volume windows */
  19.      volumes();
  20.      do i = 2 to volume.1 + 1;
  21.         close window volume.i mainwindow;
  22.      end;
  23. end;
  24. else   /* Address failed, inform user */
  25.       say 'Shutdown.exec -- Address finder failed';
  26. /* insert other commands here */
  27. say 'End of Shutdown.exec';
  28.